/*
 * Copyright (c) 2025 Huawei Device Co., Ltd.
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

#ifndef FOUNDATION_ACE_FRAMEWORKS_CORE_COMPONENTS_NG_PATTERNS_LIST_LIST_ITEM_MODEL_STATIC_H
#define FOUNDATION_ACE_FRAMEWORKS_CORE_COMPONENTS_NG_PATTERNS_LIST_LIST_ITEM_MODEL_STATIC_H

#include "base/utils/macros.h"
#include "core/components_ng/base/frame_node.h"
#include "core/components_ng/pattern/list/list_item_event_hub.h"
#include "core/components_ng/pattern/list/list_item_model.h"
#include "core/components_ng/syntax/shallow_builder.h"

namespace OHOS::Ace::NG {

class ACE_EXPORT ListItemModelStatic {
public:
    static void SetShallowBuilder(FrameNode* frameNode, const RefPtr<ShallowBuilder>& shallowBuilder);
    static void SetSticky(FrameNode* frameNode, const std::optional<V2::StickyMode>& stickyMode);
    static RefPtr<FrameNode> CreateFrameNode(
        int32_t nodeId, bool isCreateArc = false, bool isDelayedDeepRenderFunc = false);
    static void SetSelectCallback(FrameNode* frameNode, OnSelectFunc&& selectCallback);
    static void SetSelectChangeEvent(FrameNode* frameNode, OnSelectFunc&& changeEvent);
    static void SetSelectable(FrameNode* frameNode, bool selectable);
    static void SetSelected(FrameNode* frameNode, bool selected);
    static void SetEditMode(FrameNode* frameNode, uint32_t editMode);
    static void SetStyle(FrameNode* frameNode, const std::optional<V2::ListItemStyle>& style);
    static void SetDeleteArea(FrameNode* frameNode, UINode* footerNode, OnDeleteEvent&& onDelete,
        OnEnterDeleteAreaEvent&& onEnterDeleteArea, OnExitDeleteAreaEvent&& onExitDeleteArea,
        OnStateChangedEvent&& onStateChangeEvent, const std::optional<Dimension>& length, bool isStartArea);
    static void SetSwiperAction(FrameNode* frameNode, std::function<void()>&& startAction,
        std::function<void()>&& endAction, OnOffsetChangeFunc&& onOffsetChangeFunc,
        const std::optional<V2::SwipeEdgeEffect>& edgeEffect);
    static void SetAutoScale(FrameNode* frameNode, const std::optional<bool>& autoScale);
};
} // namespace OHOS::Ace::NG
#endif // FOUNDATION_ACE_FRAMEWORKS_CORE_COMPONENTS_NG_PATTERNS_LIST_LIST_ITEM_MODEL_STATIC_H
